if(CONFDATA.FIRSTMSG < 1 | CONFDATA.LASTMSG < 1) then exit
address(thorport)
REQUESTINTEGER MIN '"'CONFDATA.FIRSTMSG'"' MAX '"'CONFDATA.LASTMSG'"' INIT '"'CONFDATA.FIRSTMSG'"' TITLE '"First message in range:"' BT '"_Ok|_Cancel"'
firstmsg = result
if(rc ~= 0 | firstmsg = "RESULT") then exit
REQUESTINTEGER MIN '"'firstmsg'"' MAX '"'CONFDATA.LASTMSG'"' INIT '"'CONFDATA.LASTMSG'"' TITLE '"Last message in range:"' BT '"_Ok|_Cancel"'
lastmsg = result
if(rc ~= 0 | lastmsg = "RESULT") then exit
/* delete the messages with a progressbar */
OPENPROGRESS TITLE '"' || 'Deleting messages from ' || CURRENT.CONFNAME || '"' TOTAL lastmsg-firstmsg+1 AT '"_Abort"'
if(rc = 0) then
do
window = result
do i=firstmsg to lastmsg
address(thorport)
UPDATEPROGRESS REQ window CURRENT i-firstmsg+1 PT '"' || 'Deleting message #' || i || '"'
if(rc ~= 0) then
do
address(thorport)
CLOSEPROGRESS REQ window
exit
end
address(bbsread)
UPDATEBRMESSAGE '"'CURRENT.BBSNAME'"' '"'CURRENT.CONFNAME'"' i SETDELETED